package org.webball.server;

import org.webball.base.interfaces.IMessage;
/**
 * Class represents object of text message
 * @author Marcin Kaczor
 *
 */
public class Message implements IMessage {
	private String text="";
	
	public Message(){
		
	}
	public Message(String text){
		this.text= text;
	}
	@Override
	/**
	 * sets content of Message
	 */
	public void setText(String text) {
		this.text= text;
		
	}

	@Override
	/**
	 * gets content of Message
	 */
	public String getText() {
		return text;
		
	}
	
	@Override
	/**
	 * copies content of <code>msg</code> to this Message
	 */
	public void copy(IMessage msg) {
		text= msg.getText();
		
	}


	@Override
	/**
	 * clears content of Message 
	 */
	public void clear() {
		text= "";
		
	}
	

}
